package com.gitee.ice1938.module.admin.filemanager.fun;

import java.util.List;
import java.util.Map;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

import com.gitee.ice1938.module.admin.sysoption.fun.OptionService;

@Controller
public class FileManageController {
	@Autowired
	private OptionService optionService;
	
	/**
	 * 
	 * @param request request
	 * @param response response
	 * @param model model
	 * @return
	 */
	@RequestMapping(path = "/admin/file_manage", method = RequestMethod.GET)
	public String index(HttpServletRequest request, HttpServletResponse response, Model model) {
		List<Map<String, Object>> data = optionService.findOptions(FileManageSvc.KEY_FILE_MANAGE_REP);
		model.addAttribute("options", data);
		return "module/admin/file_manage/view_list";
	}
}
